#pragma once
#include <glm/glm.hpp>

using namespace glm;

struct Rect
{

	

	Rect(vec2 _min, vec2 _max)
	{
		min = _min;
		max = _max;
	}

	Rect(){

	}

	~Rect()
	{

	}

	bool contains(vec2 point) const {
		if (max.x > point.x > min.x && max.y > point.y > min.y)
		{
		   return true;
		}
		return false;
	}

	bool contains(Rect rect) const {
		if (max.x < rect.min.x || min.x > rect.max.x) {
			return false;
		}
		if (max.y < rect.min.y || min.y > rect.max.y) {
			return false;
		}
		return true;

	}


	bool IsInner(Rect rect)
	{
		return !(contains(rect.min) && contains(rect.max));
	}


	vec2 min = vec2(0, 0);
	vec2 max = vec2(0, 0);

};